package com.tfjybj.itoo.exam.provider.service.impl;

import com.dmsdbj.itoo.tool.base.service.impl.BaseServicePlusImpl;
import com.tfjybj.itoo.exam.entity.EvaluationSubEntity;
import com.tfjybj.itoo.exam.model.EvaluationSubModel;
import com.tfjybj.itoo.exam.provider.dao.EvaluationSubDao;
import com.tfjybj.itoo.exam.provider.service.EvaluationSubService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * TeEvaluationSubService接口实现类
 * ${base}表
 *
 * @author 杨江涛
 * @version 2.0.0
 * @since 2.0.0 2018-12-18 18:19:48
 */
@Service("teEvaluationSubService")
public class EvaluationSubServiceImpl extends BaseServicePlusImpl<EvaluationSubDao, EvaluationSubEntity> implements EvaluationSubService {
	
	//region 模板生成

    @Resource
    private EvaluationSubDao evaluationSubDao;



    //endregion

    /* **********************************以下为非模板生成的内容********************************* */

    @Override
    public boolean insertTeEvaluationSub(EvaluationSubEntity evaluationSubEntity) {
        return this.save(evaluationSubEntity);
    }

    /**
     *  根据题干id查询sub表的选项数据
     * @param mainId 题干id
     * @author 杨江涛
     * @return sub表model
     * @since 2019-1-17 17:37:39
     */
    @Override
    public List<EvaluationSubModel> querySubInfoByMainId(String mainId) {
        return evaluationSubDao.querySubInfoByMainId(mainId);
    }
}
